# all: discovery registry
# discovery: discovery.cc
# 	g++ -std=c++17 $^ -o $@ -letcd-cpp-api -lcpprest -lspdlog -lfmt -lgflags
# registry: registry.cc
# 	g++ -std=c++17 $^ -o $@ -letcd-cpp-api -lcpprest -lspdlog -lfmt -lgflags

# all: test
# test: test.cc
# 	g++ -std=c++17 $^ -o $@ -lfmt -lbrpc -lssl -lcrypto -lgflags -lprotobuf -lleveldb  

all: discovery registry
discovery: discovery.cc main.pb.cc
	g++ -std=c++17 $^ -o $@  -lspdlog -letcd-cpp-api -lcpprest -lfmt -lbrpc -lssl -lcrypto -lgflags -lprotobuf -lleveldb  
registry: registry.cc  main.pb.cc
	g++ -std=c++17 $^ -o $@  -lspdlog -letcd-cpp-api -lcpprest -lfmt -lbrpc -lssl -lcrypto -lgflags -lprotobuf -lleveldb  
.PHONY:clean
clean:
	rm -rf discovery registry test